﻿using Common.ECS;
using ResourceSystem;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using UnityEngine;
public class LookComponent: AbstractComponent,ICollisionComponent
{
    public string Path { get; set; }

    public string SelfTag { get; set; }

    public string TargetTag { get; set; }

    private List<GameObject> enterObjs = new List<GameObject>();

    public List<GameObject> EnterObjs
    {
        get
        {
            return enterObjs;
        }
    }

    public override void Init(Entity owner)
    {
        base.Init(owner);
        CollisionAdapter collisionArea = Owner.GetAdapterByPath<CollisionAdapter>(Path);
        collisionArea.RegisterComponent(this);
    }
}